## 20ms 2984KB 5Min
## eval()
from fractions import Fraction
a,b=input().split()

def s2int(snum:str):
    # num=eval(snum)
    try:
        num=int(snum)
        return num
    except:
        return Fraction(snum)

a,b=Fraction(a),Fraction(b)

def f2s(frac):
    if frac<0:
        return "({frac})"
    return "{frac}"

print(f"{a} + {b} = {a+b}")
print(f"{a} - {b} = {a-b}")
print(f"{a} * {b} = {a*b}")
print(f"{a} / {b} = {a/b}")
